package com.lut.edu.apm.webCenter.expection;

/**
 * @author Zhao Suzhen
 * @date `2024/6/4`
 */
public class NoTokenException extends RuntimeException {

    private static final long serialVersionUID = 1L;

    // 自定义属性，用于存储异常发生时的请求URL
    private String requestUrl;

    // 自定义属性，用于存储异常发生时的请求方法
    private String requestMethod;

    // 构造函数，用于在抛出异常时提供更多的上下文信息
    public NoTokenException(String message, String requestUrl, String requestMethod) {
        super(message);
        this.requestUrl = requestUrl;
        this.requestMethod = requestMethod;
    }

    // Getter和Setter方法，用于获取和设置自定义属性
    public String getRequestUrl() {
        return requestUrl;
    }

    public void setRequestUrl(String requestUrl) {
        this.requestUrl = requestUrl;
    }

    public String getRequestMethod() {
        return requestMethod;
    }

    public void setRequestMethod(String requestMethod) {
        this.requestMethod = requestMethod;
    }
}